package cn.coderliu.voteweb.common.exception;

/**
 * @author liu
 * 自定义异常类
 */

public class WebException extends RuntimeException{

    private String code;
    private String message;

    public void setCode(String code) {
        this.code = code;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public String getCode(){
        return  this.code;
    }

    @Override
    public String getMessage(){
        return this.message;
    }

    public WebException(String code,String message,Throwable cause){
        super(cause);
        this.code=code;
        this.message=message;
    }
}
